Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(ui): replace hardcoded farms with fetched from the graph #61

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

mainnet-pat
Copy link
Collaborator

Assess #53
Remove hardcoded farms and fetch them from the graph.
This is mostly a revert of your changes with some fixes. The TVL and ROI numbers are slightly different now, but are consistent with old ones

@vercel
Copy link

vercel bot commented Nov 24, 2021

This pull request is being automatically deployed with Vercel (learn more).
To see the status of your deployment, click below or on the icon next to each commit.

🔍 Inspect: https://vercel.com/mistswapdex/mistswap-interface/3LGzyXHiwEAp4Cbe2MfPyDzj41zk
✅ Preview: https://mistswap-interface-git-fork-mainnet-pat-graphfarms-mistswapdex.vercel.app

[Deployment for 77ea31f failed]

@kasumi-1
Copy link
Member

This doesn't have rpc fallback? I don't trust graph server to not fail.

@mainnet-pat
Copy link
Collaborator Author

mainnet-pat commented Nov 24, 2021

Omg totally overseen that. Do you mean both logic pieces should be kept?

@kasumi-1
Copy link
Member

Ya - I think detecting if useFarms or something similar fails to cause rpc path?

@mainnet-pat
Copy link
Collaborator Author

Hi, this became a heavy refactor. Now I see that joy has some erroneous data in the graph showing funny tvl and apr.
This is a draft. My react-fu turned out to be weak when doing such complex things, if I uncomment fetching the pending sushi for graph farms react gets angry at me for messing up the hook order. Do you have any hints?

@mainnet-pat
Copy link
Collaborator Author

Oops it seems not to build because of conditionals. Any further guidance is appreciated.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants